<?php

/**
 * @author Djordje Zeljic
 * Date: Feb 27, 2010 18:19:51 AM
 */
if ( ! defined('BASEPATH')) exit('No direct script access allowed');

class Mloader {

    public $model;
    public $mmodel;

    function __construct () {
        $this->model = & get_instance();
    }// construct of mloader

    function load($location, $modelname){
        $this->model->load->model($location,$modelname);
        $this->mmodel = $this->model->$modelname;
        return $this->model->$modelname;
    }

    function unload($modelname){
        unset($this->model->$modelname);
    }

}
?>